<template>
  <div id="client">  

  <el-form ref="form"  label-width="80px">  

           <el-row>  
            <el-col :span="12" style="display:flex;">
               <div style="height:38px;line-height:38px;width:150px;"> 
                  <i class="el-icon-back" @click="goBack"></i> 
                  {{ $route.query.name }} 
                </div>
            </el-col> 
            <el-col :span="12" style="text-align: right;">
              
            </el-col>   
        </el-row>

    </el-form>

   <!-- 渲染数据list -->
   <client-list :data="data"  @up_list_fun="list_fun"> </client-list>

   <div style="margin-top:20px;text-align: center;">
      <el-pagination
        background
        @current-change="handleCurrentChange"
        :page-size="10"  
        layout="prev, pager, next, jumper"
        :total="count">
      </el-pagination>
    </div>
      
    

      
  </div>
</template>

<script>
import ClientList from '@/view/Aftersale/ClientList'
export default {
  name: 'client',
  data () {
    return {
        data:[],
        page:1,
        count:0,
        my_id:'',
    }
  },
 components:{
    ClientList
  },
  created(){
      this.my_id = this.$route.query.id
      this.list_fun()
  },
  mounted (){
    
  },
  methods: {
 
    list_fun(){
         
        // this.post("/customer_service/listOfSpeechcraft", {
        //         page:this.page,
        //         csid:this.my_id,
        //     }).then(res => {
        //       this.count = res.result.count
        //       this.data = res.result.list
        //       //console.log(res)
        //     })
          
      },
    goBack() {
        this.$router.go(-1)
    },
     handleSizeChange(val) {
        console.log(`每页 ${val} 条`);
    },
    handleCurrentChange(val) {
        this.page = val
        this.list_fun()
        console.log(`当前页: ${val}`);
      }
  }
}
</script>


<style scoped>
</style>
